package org.daochong.fastdev.funcs;

import java.sql.SQLException;

import org.daochong.fastdev.Context;
import org.daochong.fastdev.Function;

public class EndFunction implements Function {

	public boolean is(String id) {
		return "end".equals(id);
	}

	public void exec(String key, String prop, Context context) throws SQLException {
		if (is(key)) {
			context.setEnd((prop == null || "true".equalsIgnoreCase(prop)));
		}
	}

}
